{% raw %}
<script type="text/x-template" id="id-comment-temp-block">
{% for comment in comments %}
{% assign commentIndex = forloop.index %}
<div class="comment_warp">
        <div class="comment_warp-header mo-flex mo-j-space-between">
          <div class="mo-flex">
            <img class="comment_warp-header-nation" style="height: auto;" src="{{comment.country_id | current_countrys|public_front_asset_url }}?x-oss-process=image/resize,m_lfit,w_200" />
            <span>{{comment.customer_name}} <span style="color:#888888;margin-left:4px">{% if storeConfig.hide_time == '0' %}{% if comment.created_at !=0 %} {{comment.created_at_str}} {% endif %}{% endif %}</span></span>
          </div>
        </div>
        <div class="comment_warp-score">
          
          {% for index in (1..5) %}
          {%- capture fill_color -%}
            {%- if index <= comment.star -%}
              {{theme_config.global.product_score_selected_color | default:'#F8AD6B'}}
              {%- else -%}
              {{theme_config.global.product_score_uncheck_color | default:'#bbbbbb'}} 
            {%- endif -%}
          {%- endcapture -%}
          <svg t="1632626527998" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7121" width="16" height="16">
            <path d="M512 0l122.88 352.96 389.12 2.752-300.8 238.08 118.272 380.032L512 747.392l-329.6 226.496L293.312 588.8 0.32 355.776l389.12-2.752z" fill="{{fill_color}}" p-id="7122"></path>
          </svg>
          {% endfor %}

        </div>
        <div class="comment_warp-content">
          {% if comment.comment_title != "" and storeConfig.comments_title_require != '0'  %}
            <p class="comment_warp-content-lable" style="font-weight: bold; color: #333;    margin-bottom: 4px;">{{comment.comment_title}}</p>
          {% endif %}

          <p class="comment_warp-content-lable">{{comment.content}}</p>
          <!-- <div class="comment_warp-content-review">{{lang.comments.show_fill_review}}</div> -->
          <div class="comment_warp-images">
            {% if  comment.images.src %}
            {% for image in comment.images.src %}
            {% assign keyIndex = forloop.index %}
             {%- assign params = image |public_front_asset_url|parseUrlParams: 'array' -%}
            {% if params.video %}
            <div style="position: relative;">
             <svg class="video-icon" height="32" p-id="7442" t="1661151421785" version="1.1"
              viewbox="0 0 1024 1024" height="32" xmlns="http://www.w3.org/2000/svg">
              <path d="M1024 512.236308A512 512 0 1 1 512 0a512.590769 512.590769 0 0 1 512 512.236308"
                fill="#D9DFE9" p-id="7443"></path>
              <path
                d="M691.396923 512.236308a58.801231 58.801231 0 0 1-12.248615 36.312615 187.352615 187.352615 0 0 1-14.217846 15.990154l-3.072 2.953846a775.876923 775.876923 0 0 1-203.106462 135.364923 176.482462 176.482462 0 0 1-47.261538 13.942154h-2.008616a64.196923 64.196923 0 0 1-56.477538-33.792 276.873846 276.873846 0 0 1-12.248616-45.331692 903.837538 903.837538 0 0 1-7.640615-126.03077 780.327385 780.327385 0 0 1 8.664615-129.96923 323.308308 323.308308 0 0 1 9.176616-36.352 65.024 65.024 0 0 1 28.514461-30.79877 72.625231 72.625231 0 0 1 32.019693-7.483076 176.915692 176.915692 0 0 1 42.299076 11.460923 779.067077 779.067077 0 0 1 207.675077 137.334153c7.168 7.010462 14.808615 15.478154 16.817231 17.447385a61.833846 61.833846 0 0 1 13.233231 38.793846"
                fill="#555273" p-id="7444"></path>
            </svg>
            <img src="{{ 'empty_loading.png' | public_asset_abs_dir_url }}" data-src="{{image|public_front_asset_url}}" data-parent="{{comment.currentIndex}}"  data-index="{{keyIndex}}" />
            </div>
               {% else %}
              <img src="{{ 'empty_loading.png' | public_asset_abs_dir_url }}" data-src="{{image|public_front_asset_url}}" data-parent="{{comment.currentIndex}}"  data-index="{{keyIndex}}" />
            {% endif %}
            {% endfor %}
            {% endif %}
          </div>

          {% if comment.reply_content != "" %}
          <div class="comment-reply-warp">
            <div class="comment-reply-warp-title">
              <span class="comment-reply-warp-name">{{lang.comments.reply}}:</span>
              {% if comment.replied_at != 0  and storeConfig.hide_time != '1' %}
              <span class="comment-reply-warp-date">{{comment.replied_at_str}}</span>
              {% endif %}
            </div>
            <div class="comment-reply-warp-content">{{comment.reply_content}}</div>
          </div>
          {% endif %}
        </div>
        {% if is_product %}
        <div class="comment_warp-product">
          <div class="comment_warp-content-item mo-flex">
            <a class="comment_warp-content-item-images" href="/products/{{comment.handle}}?data_from={{data_from}}">
              <img src="{{ 'empty_loading.png' | public_asset_abs_dir_url }}" alt="{{comment.alt | default:comment.title }}" data-src="{{comment.src|public_front_asset_url}}" />
            </a>
            <div class="comment_warp-content-item-cell">
              <a class="comment_warp-content-item-cell-text" href="/products/{{comment.handle}}?data_from={{data_from}}">{{comment.title}}</a>
              <div class="comment_warp-content-item-cell-text">{{comment.price}}</div>
              <a href="{{comment.url}}" class="comment_warp-content-item-cell-reviews">{{lang.comments_detail.reviews}} {% if comment.count > 1 %}({{comment.count}}){% endif %}</a>
            </div>
          </div>

        </div>
        {% endif %}
</div>
{% endfor %}
</script>
{% endraw %}

